package com.tuanzi.loan.business.repository.templateConf;

import com.tuanzi.loan.business.entity.templateConf.LoanApiActivityEntity;
import com.tuanzi.loan.business.repository.templateConf.custom.ActivityRepositoryCustom;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.Modifying;
import org.springframework.data.jpa.repository.Query;
import org.springframework.data.repository.query.Param;

public interface ActivityRepository extends JpaRepository<LoanApiActivityEntity, Long>, ActivityRepositoryCustom {

    @Modifying
    @Query("update LoanApiActivityEntity set status = :status where id = :id")
    int updateStatus(@Param("id") Long id, @Param("status") Short status);
}
